home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 15
/
Aminet 15 - Nov 1996.iso
/
Aminet
/
dev
/
gcc
/
ixemsdk.lha
/
man
/
cat3
/
rand.0
< prev
next >
Wrap
Text File
|
1996-09-02
|
1KB
|
37 lines
RAND(3) UNIX Programmer's Manual RAND(3)
NNAAMMEE
rraanndd, ssrraanndd - bad random number generator
SSYYNNOOPPSSIISS
##iinncclluuddee <<ssttddlliibb..hh>>
_v_o_i_d
ssrraanndd(_u_n_s_i_g_n_e_d _s_e_e_d)
_i_n_t
rraanndd(_v_o_i_d)
DDEESSCCRRIIPPTTIIOONN
TThheessee iinntteerrffaacceess aarree oobbssoolleetteedd bbyy rraannddoomm((33))..
The rraanndd() function computes a sequence of pseudo-random integers in the
range of 0 to RAND_MAX (as defined by the header file <_s_t_d_l_i_b_._h>).
The ssrraanndd() function sets its argument as the seed for a new sequence of
pseudo-random numbers to be returned by rraanndd(). These sequences are re-
peatable by calling ssrraanndd() with the same seed value.
If no seed value is provided, the functions are automatically seeded with
a value of 1.
SSEEEE AALLSSOO
random(3)
SSTTAANNDDAARRDDSS
The rraanndd() and ssrraanndd() functions conform to ANSI C3.159-1989 (``ANSI
C'').
BSD Experimental June 29, 1991 1